<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>PolkitBackendInteractiveAuthority</title>
<meta name="generator" content="DocBook XSL Stylesheets V1.76.1">
<link rel="home" href="index.html" title="polkit Reference Manual">
<link rel="up" href="ref-backend-api.html" title="Part IV. Backend API Reference">
<link rel="prev" href="PolkitBackendAuthority.html" title="PolkitBackendAuthority">
<link rel="next" href="PolkitBackendLocalAuthority.html" title="PolkitBackendLocalAuthority">
<meta name="generator" content="GTK-Doc V1.18 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2">
<tr valign="middle">
<td><a accesskey="p" href="PolkitBackendAuthority.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td>
<td><a accesskey="u" href="ref-backend-api.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td>
<td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td>
<th width="100%" align="center">polkit Reference Manual</th>
<td><a accesskey="n" href="PolkitBackendLocalAuthority.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td>
</tr>
<tr><td colspan="5" class="shortcuts">
<a href="#PolkitBackendInteractiveAuthority.synopsis" class="shortcut">Top</a>
                   | 
                  <a href="#PolkitBackendInteractiveAuthority.description" class="shortcut">Description</a>
                   | 
                  <a href="#PolkitBackendInteractiveAuthority.object-hierarchy" class="shortcut">Object Hierarchy</a>
</td></tr>
</table>
<div class="refentry">
<a name="PolkitBackendInteractiveAuthority"></a><div class="titlepage"></div>
<div class="refnamediv"><table width="100%"><tr>
<td valign="top">
<h2><span class="refentrytitle"><a name="PolkitBackendInteractiveAuthority.top_of_page"></a>PolkitBackendInteractiveAuthority</span></h2>
<p>PolkitBackendInteractiveAuthority — Interactive Authority</p>
</td>
<td valign="top" align="right"></td>
</tr></table></div>
<div class="refsect1">
<a name="PolkitBackendInteractiveAuthority.stability-level"></a><h2>Stability Level</h2>
Unstable, unless otherwise indicated
</div>
<div class="refsynopsisdiv">
<a name="PolkitBackendInteractiveAuthority.synopsis"></a><h2>Synopsis</h2>
<pre class="synopsis">                    <a class="link" href="PolkitBackendInteractiveAuthority.html#PolkitBackendInteractiveAuthority-struct" title="PolkitBackendInteractiveAuthority">PolkitBackendInteractiveAuthority</a>;
struct              <a class="link" href="PolkitBackendInteractiveAuthority.html#PolkitBackendInteractiveAuthorityClass" title="struct PolkitBackendInteractiveAuthorityClass">PolkitBackendInteractiveAuthorityClass</a>;
<a href="http://library.gnome.org/devel/glib/unstable/glib-Doubly-Linked-Lists.html#GList"><span class="returnvalue">GList</span></a> *             <a class="link" href="PolkitBackendInteractiveAuthority.html#polkit-backend-interactive-authority-get-admin-identities" title="polkit_backend_interactive_authority_get_admin_identities ()">polkit_backend_interactive_authority_get_admin_identities</a>
                                                        (<em class="parameter"><code><a class="link" href="PolkitBackendInteractiveAuthority.html" title="PolkitBackendInteractiveAuthority"><span class="type">PolkitBackendInteractiveAuthority</span></a> *authority</code></em>,
                                                         <em class="parameter"><code><a class="link" href="PolkitSubject.html" title="PolkitSubject"><span class="type">PolkitSubject</span></a> *caller</code></em>,
                                                         <em class="parameter"><code><a class="link" href="PolkitSubject.html" title="PolkitSubject"><span class="type">PolkitSubject</span></a> *subject</code></em>,
                                                         <em class="parameter"><code><a class="link" href="PolkitIdentity.html" title="PolkitIdentity"><span class="type">PolkitIdentity</span></a> *user_for_subject</code></em>,
                                                         <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *action_id</code></em>,
                                                         <em class="parameter"><code><a class="link" href="PolkitDetails.html" title="PolkitDetails"><span class="type">PolkitDetails</span></a> *details</code></em>);
<a class="link" href="PolkitActionDescription.html#PolkitImplicitAuthorization"><span class="returnvalue">PolkitImplicitAuthorization</span></a> <a class="link" href="PolkitBackendInteractiveAuthority.html#polkit-backend-interactive-authority-check-authorization-sync" title="polkit_backend_interactive_authority_check_authorization_sync ()">polkit_backend_interactive_authority_check_authorization_sync</a>
                                                        (<em class="parameter"><code><a class="link" href="PolkitBackendInteractiveAuthority.html" title="PolkitBackendInteractiveAuthority"><span class="type">PolkitBackendInteractiveAuthority</span></a> *authority</code></em>,
                                                         <em class="parameter"><code><a class="link" href="PolkitSubject.html" title="PolkitSubject"><span class="type">PolkitSubject</span></a> *caller</code></em>,
                                                         <em class="parameter"><code><a class="link" href="PolkitSubject.html" title="PolkitSubject"><span class="type">PolkitSubject</span></a> *subject</code></em>,
                                                         <em class="parameter"><code><a class="link" href="PolkitIdentity.html" title="PolkitIdentity"><span class="type">PolkitIdentity</span></a> *user_for_subject</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> subject_is_local</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> subject_is_active</code></em>,
                                                         <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *action_id</code></em>,
                                                         <em class="parameter"><code><a class="link" href="PolkitDetails.html" title="PolkitDetails"><span class="type">PolkitDetails</span></a> *details</code></em>,
                                                         <em class="parameter"><code><a class="link" href="PolkitActionDescription.html#PolkitImplicitAuthorization"><span class="type">PolkitImplicitAuthorization</span></a> implicit</code></em>,
                                                         <em class="parameter"><code><a class="link" href="PolkitDetails.html" title="PolkitDetails"><span class="type">PolkitDetails</span></a> *out_details</code></em>);
</pre>
</div>
<div class="refsect1">
<a name="PolkitBackendInteractiveAuthority.object-hierarchy"></a><h2>Object Hierarchy</h2>
<pre class="synopsis">
  <a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#GObject">GObject</a>
   +----<a class="link" href="PolkitBackendAuthority.html" title="PolkitBackendAuthority">PolkitBackendAuthority</a>
         +----PolkitBackendInteractiveAuthority
               +----<a class="link" href="PolkitBackendLocalAuthority.html" title="PolkitBackendLocalAuthority">PolkitBackendLocalAuthority</a>
</pre>
</div>
<div class="refsect1">
<a name="PolkitBackendInteractiveAuthority.description"></a><h2>Description</h2>
<p>
An subclass of <a class="link" href="PolkitBackendAuthority.html" title="PolkitBackendAuthority"><span class="type">PolkitBackendAuthority</span></a> that supports interaction
with authentication agents.
</p>
</div>
<div class="refsect1">
<a name="PolkitBackendInteractiveAuthority.details"></a><h2>Details</h2>
<div class="refsect2">
<a name="PolkitBackendInteractiveAuthority-struct"></a><h3>PolkitBackendInteractiveAuthority</h3>
<pre class="programlisting">typedef struct _PolkitBackendInteractiveAuthority PolkitBackendInteractiveAuthority;</pre>
<p>
The <a class="link" href="PolkitBackendInteractiveAuthority.html" title="PolkitBackendInteractiveAuthority"><span class="type">PolkitBackendInteractiveAuthority</span></a> struct should not be accessed directly.
</p>
</div>
<hr>
<div class="refsect2">
<a name="PolkitBackendInteractiveAuthorityClass"></a><h3>struct PolkitBackendInteractiveAuthorityClass</h3>
<pre class="programlisting">struct PolkitBackendInteractiveAuthorityClass {
  PolkitBackendAuthorityClass parent_class;

  /* VTable */
  GList *                     (*get_admin_identities)          (PolkitBackendInteractiveAuthority *authority,
                                                                PolkitSubject                     *caller,
                                                                PolkitSubject                     *subject,
                                                                PolkitIdentity                    *user_for_subject,
                                                                const gchar                       *action_id,
                                                                PolkitDetails                     *details);

  PolkitImplicitAuthorization (*check_authorization_sync) (PolkitBackendInteractiveAuthority *authority,
                                                           PolkitSubject                     *caller,
                                                           PolkitSubject                     *subject,
                                                           PolkitIdentity                    *user_for_subject,
                                                           gboolean                           subject_is_local,
                                                           gboolean                           subject_is_active,
                                                           const gchar                       *action_id,
                                                           PolkitDetails                     *details,
                                                           PolkitImplicitAuthorization        implicit,
                                                           PolkitDetails                     *out_details);
};
</pre>
<p>
Class structure for <a class="link" href="PolkitBackendInteractiveAuthority.html" title="PolkitBackendInteractiveAuthority"><span class="type">PolkitBackendInteractiveAuthority</span></a>.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><a class="link" href="PolkitBackendAuthority.html#PolkitBackendAuthorityClass" title="struct PolkitBackendAuthorityClass"><span class="type">PolkitBackendAuthorityClass</span></a> <em class="structfield"><code><a name="PolkitBackendInteractiveAuthorityClass.parent-class"></a>parent_class</code></em>;</span></p></td>
<td>The parent class.</td>
</tr>
<tr>
<td><p><span class="term"><em class="structfield"><code><a name="PolkitBackendInteractiveAuthorityClass.get-admin-identities"></a>get_admin_identities</code></em> ()</span></p></td>
<td>Returns list of identities for administrator authentication or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> to use the default
implementation. See <a class="link" href="PolkitBackendInteractiveAuthority.html#polkit-backend-interactive-authority-get-admin-identities" title="polkit_backend_interactive_authority_get_admin_identities ()"><code class="function">polkit_backend_interactive_authority_get_admin_identities()</code></a> for details.</td>
</tr>
<tr>
<td><p><span class="term"><em class="structfield"><code><a name="PolkitBackendInteractiveAuthorityClass.check-authorization-sync"></a>check_authorization_sync</code></em> ()</span></p></td>
<td>Checks for an authorization or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> to use the default implementation.
See <a class="link" href="PolkitBackendInteractiveAuthority.html#polkit-backend-interactive-authority-check-authorization-sync" title="polkit_backend_interactive_authority_check_authorization_sync ()"><code class="function">polkit_backend_interactive_authority_check_authorization_sync()</code></a> for details.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="polkit-backend-interactive-authority-get-admin-identities"></a><h3>polkit_backend_interactive_authority_get_admin_identities ()</h3>
<pre class="programlisting"><a href="http://library.gnome.org/devel/glib/unstable/glib-Doubly-Linked-Lists.html#GList"><span class="returnvalue">GList</span></a> *             polkit_backend_interactive_authority_get_admin_identities
                                                        (<em class="parameter"><code><a class="link" href="PolkitBackendInteractiveAuthority.html" title="PolkitBackendInteractiveAuthority"><span class="type">PolkitBackendInteractiveAuthority</span></a> *authority</code></em>,
                                                         <em class="parameter"><code><a class="link" href="PolkitSubject.html" title="PolkitSubject"><span class="type">PolkitSubject</span></a> *caller</code></em>,
                                                         <em class="parameter"><code><a class="link" href="PolkitSubject.html" title="PolkitSubject"><span class="type">PolkitSubject</span></a> *subject</code></em>,
                                                         <em class="parameter"><code><a class="link" href="PolkitIdentity.html" title="PolkitIdentity"><span class="type">PolkitIdentity</span></a> *user_for_subject</code></em>,
                                                         <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *action_id</code></em>,
                                                         <em class="parameter"><code><a class="link" href="PolkitDetails.html" title="PolkitDetails"><span class="type">PolkitDetails</span></a> *details</code></em>);</pre>
<p>
Gets a list of identities to use for administrator authentication.
</p>
<p>
The default implementation returns a list with a single element for the super user.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>authority</code></em> :</span></p></td>
<td>A <a class="link" href="PolkitBackendInteractiveAuthority.html" title="PolkitBackendInteractiveAuthority"><span class="type">PolkitBackendInteractiveAuthority</span></a>.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>caller</code></em> :</span></p></td>
<td>The subject that is inquiring whether <em class="parameter"><code>subject</code></em> is authorized.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>subject</code></em> :</span></p></td>
<td>The subject we are about to authenticate for.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>user_for_subject</code></em> :</span></p></td>
<td>The user of the subject we are about to authenticate for.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>action_id</code></em> :</span></p></td>
<td>The action we are about to authenticate for.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>details</code></em> :</span></p></td>
<td>Details about the action.</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>A list of <a class="link" href="PolkitIdentity.html" title="PolkitIdentity"><span class="type">PolkitIdentity</span></a> objects. Free each element
<a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#g-object-unref"><code class="function">g_object_unref()</code></a>, then free the list with <a href="http://library.gnome.org/devel/glib/unstable/glib-Doubly-Linked-Lists.html#g-list-free"><code class="function">g_list_free()</code></a>.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="polkit-backend-interactive-authority-check-authorization-sync"></a><h3>polkit_backend_interactive_authority_check_authorization_sync ()</h3>
<pre class="programlisting"><a class="link" href="PolkitActionDescription.html#PolkitImplicitAuthorization"><span class="returnvalue">PolkitImplicitAuthorization</span></a> polkit_backend_interactive_authority_check_authorization_sync
                                                        (<em class="parameter"><code><a class="link" href="PolkitBackendInteractiveAuthority.html" title="PolkitBackendInteractiveAuthority"><span class="type">PolkitBackendInteractiveAuthority</span></a> *authority</code></em>,
                                                         <em class="parameter"><code><a class="link" href="PolkitSubject.html" title="PolkitSubject"><span class="type">PolkitSubject</span></a> *caller</code></em>,
                                                         <em class="parameter"><code><a class="link" href="PolkitSubject.html" title="PolkitSubject"><span class="type">PolkitSubject</span></a> *subject</code></em>,
                                                         <em class="parameter"><code><a class="link" href="PolkitIdentity.html" title="PolkitIdentity"><span class="type">PolkitIdentity</span></a> *user_for_subject</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> subject_is_local</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> subject_is_active</code></em>,
                                                         <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *action_id</code></em>,
                                                         <em class="parameter"><code><a class="link" href="PolkitDetails.html" title="PolkitDetails"><span class="type">PolkitDetails</span></a> *details</code></em>,
                                                         <em class="parameter"><code><a class="link" href="PolkitActionDescription.html#PolkitImplicitAuthorization"><span class="type">PolkitImplicitAuthorization</span></a> implicit</code></em>,
                                                         <em class="parameter"><code><a class="link" href="PolkitDetails.html" title="PolkitDetails"><span class="type">PolkitDetails</span></a> *out_details</code></em>);</pre>
<p>
Checks whether <em class="parameter"><code>subject</code></em> is authorized to perform the action
specified by <em class="parameter"><code>action_id</code></em> and <em class="parameter"><code>details</code></em>. The implementation may
append key/value pairs to <em class="parameter"><code>out_details</code></em> to return extra information
to <em class="parameter"><code>caller</code></em>.
</p>
<p>
The default implementation of this method simply returns <em class="parameter"><code>implicit</code></em>.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>authority</code></em> :</span></p></td>
<td>A <a class="link" href="PolkitBackendInteractiveAuthority.html" title="PolkitBackendInteractiveAuthority"><span class="type">PolkitBackendInteractiveAuthority</span></a>.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>caller</code></em> :</span></p></td>
<td>The subject that is inquiring whether <em class="parameter"><code>subject</code></em> is authorized.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>subject</code></em> :</span></p></td>
<td>The subject we are checking an authorization for.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>user_for_subject</code></em> :</span></p></td>
<td>The user of the subject we are checking an authorization for.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>subject_is_local</code></em> :</span></p></td>
<td>
<a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> if the session for <em class="parameter"><code>subject</code></em> is local.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>subject_is_active</code></em> :</span></p></td>
<td>
<a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> if the session for <em class="parameter"><code>subject</code></em> is active.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>action_id</code></em> :</span></p></td>
<td>The action we are checking an authorization for.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>details</code></em> :</span></p></td>
<td>Details about the action.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>implicit</code></em> :</span></p></td>
<td>A <a class="link" href="PolkitActionDescription.html#PolkitImplicitAuthorization"><span class="type">PolkitImplicitAuthorization</span></a> value computed from the policy file and <em class="parameter"><code>subject</code></em>.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>out_details</code></em> :</span></p></td>
<td>A <a class="link" href="PolkitDetails.html" title="PolkitDetails"><span class="type">PolkitDetails</span></a> object that will be return to <em class="parameter"><code>caller</code></em>.</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>A <a class="link" href="PolkitActionDescription.html#PolkitImplicitAuthorization"><span class="type">PolkitImplicitAuthorization</span></a> that specifies if the subject is authorized or whether
authentication is required.</td>
</tr>
</tbody>
</table></div>
</div>
</div>
</div>
<div class="footer">
<hr>
          Generated by GTK-Doc V1.18</div>
</body>
</html>